import { getWorkspace } from '@/api/dashboard'
const state = {
  user: {}
}

const mutations = {
  getUser(state, user) {
    state.user = user
  }

}

const actions = {
  async getWorkspace(context) {
    const res = await getWorkspace()
    console.log(res)
    context.commit('getUser', res.data)
  }
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}
